Skip to content

Fix heartbeat waiting logic in palette2.py#2

Open
cfelicio wants to merge 1 commit intomasterfrom
palette-2-patch-1
Open

Fix heartbeat waiting logic in palette2.py#2
cfelicio wants to merge 1 commit intomasterfrom
palette-2-patch-1

Conversation

@cfelicio
Copy link
Owner

In some situations, the existing _wait_for_heartbeat causes a shutdown and the following error when using PALETTE_CONNECT:

TypeError: '<' not supported between instances of 'NoneType' and 'float'

PALETTE_CONNECT now works (tested with a Palette 2 and a Palette 2 PRO). I'm not quite sure why this happens with one of my printers but not the other one, what I figured out so far is that the serial communication happens almost instantly on printer 1, while printer 2 struggles in the beginning due to a slower motherboard. It should properly allow for a timeout, or fail more gracefully instead of a shutdown.

In some situations, the existing _wait_for_heartbeat causes a shutdown and the following error when using PALETTE_CONNECT:

TypeError: '<' not supported between instances of 'NoneType' and 'float'

PALETTE_CONNECT now works (tested with a Palette 2 and a Palette 2 PRO). I'm not quite sure why this happens with one of my printers but not the other one, what I figured out so far is that the serial communication happens almost instantly on printer 1, while printer 2 struggles in the beginning due to a slower motherboard. It should properly allow for a timeout, or fail more gracefully instead of a shutdown.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant